﻿using System;
using System.IO;
using System.Linq;
using System.Collections.Generic;
using System.Text;
using System.Web;

namespace HashFoo.Rest.ServerTests.FakeHttpStack
{
    public class FakeHttpResponse : HttpResponseBase
    {
        StringBuilder _outputBuilder = new StringBuilder();

        public override void Write(string s)
        {
            _outputBuilder.Append(s);
        }

        public override void Write(object obj)
        {
            Write(obj.ToString());
        }

        public override string ContentType { get; set; }

        public string ResponseText
        {
            get { return _outputBuilder.ToString(); }
        }

        public override void Close()
        {
            // do nothing.
        }
    }
}